package com.onlineMIS.ORM.entity.headQ.inventoryFlow;

import com.onlineMIS.ORM.entity.headQ.barcodeGentor.ProductBarcode;
import com.onlineMIS.common.Common_util;

public class HqInventoryChangeDetailsVO {
	public static final String STATE_CLOSED = "closed";
	public static final String STATE_OPEN = "open";
	
	private String id;
	private String storeName;
	private String name;
	private String barcode;

	private int inventory;
	
	private String state;
	private String param;
	
	private ProductBarcode pb;
	
	private int parentId = 0;
	private int storeId = 1;
	private String storeIds;
	private int yearId = 0;
	private int quarterId = 0;
	private int brandId = 0;
	private int categoryId = 0;
	private int categoryLevelId = 0;
	private int pbId;
	//上期数量
	private int beforeAmount;
	//上期金额
	private double beforeAmountMoney;
	
	//本期入库：
	//本期采购数量
	private int periodPurchaseNums;
	//本期采购金额
	private double periodPurchaseMoneys;
	//本期销售退货数量
	private int periodSaleReturnNums;
	//本期销售退货金额
	private double periodSaleReturnMoneys;
	//本期报溢数量
	private int periodOverflowNums;
	//本期报溢金额
	private double periodOverflowMoneys;
	//本期获赠数量
	private int periodReceiveNums;
	//本期获赠金额
	private double periodReceiveMoneys;
	//本期库存调入数量
	private int periodCallInNums;
	//本期库存调入金额
	private double periodCallInMoneys;
	//入库合计数量
	private int periodEnterNums;
	//入库合计金额
	private double periodEnterMoneys;
	
	
	//本期出库：
	//本期销售数量
	private int periodSaleNums;
	//本期销售金额
	private double periodSaleMoneys;
	//本期采购退货数量
	private int periodPurchaseReturnNums;
	//本期采购退货金额
	private double periodPurchaseReturnMoneys;
	//本期报损数量
	private int periodLossNums;
	//本期报损金额
	private double periodLossMoneys;
	//本期赠送数量
	private int periodGiftNums;
	//本期赠送金额
	private double periodGiftMoneys;
	//本期库存调出数量
	private int periodOutNums;
	//本期库存调出金额
	private double periodOutMoneys;
	//出库合计数量
	private int periodOutBoundNums;
	//出库合计金额
	private double periodOutBoundMoneys;
	
	
	//期末：
	private int totalQuantity;
	private double totalAmount;
	
	public HqInventoryChangeDetailsVO() {
		
	}
	
	public HqInventoryChangeDetailsVO(int parentId, String name, int inventory, double recCost, String state, String storeIds, int yearId, int quarterId, int brandId,int categoryId,int categoryLevelId){
		this.setId(Common_util.getUUID());
		this.setParentId(parentId);
		this.setName(name);
		this.setInventory(inventory);		
		this.setState(state);
		this.setStoreIds(storeIds);
		this.setYearId(yearId);
		this.setQuarterId(quarterId);
		this.setBrandId(brandId);
		this.setCategoryId(categoryId);
		this.setCategoryLevelId(categoryLevelId);
		

	}
	
	public void initAmountTo() {
		//入库合计
		this.periodEnterNums = this.periodPurchaseNums + this.periodSaleReturnNums + this.periodOverflowNums + this.periodReceiveNums + this.periodCallInNums;
		this.periodEnterMoneys = this.periodPurchaseMoneys + this.periodSaleReturnMoneys + this.periodOverflowMoneys +this.periodReceiveMoneys + this.periodCallInMoneys;
		//出库合计
		this.periodOutBoundNums = this.periodSaleNums + this. periodPurchaseReturnNums + this.periodLossNums + this. periodGiftNums+ this. periodOutNums;
		this.periodOutBoundMoneys = this.periodSaleMoneys+ this. periodPurchaseReturnMoneys+ this.  periodLossMoneys+ this. periodGiftMoneys+ this. periodOutMoneys;
	}

	
	

	public String getStoreIds() {
		return storeIds;
	}

	public void setStoreIds(String storeIds) {
		this.storeIds = storeIds;
	}

	public String getBarcode() {
		return barcode;
	}

	public void setBarcode(String barcode) {
		this.barcode = barcode;
	}

	public int getCategoryId() {
		return categoryId;
	}

	public void setCategoryId(int categoryId) {
		this.categoryId = categoryId;
	}

	public int getCategoryLevelId() {
		return categoryLevelId;
	}

	public void setCategoryLevelId(int categoryLevelId) {
		this.categoryLevelId = categoryLevelId;
	}

	public String getStoreName() {
		return storeName;
	}

	public void setStoreName(String storeName) {
		this.storeName = storeName;
	}

	public int getPbId() {
		return pbId;
	}

	public void setPbId(int pbId) {
		this.pbId = pbId;
	}

	public int getStoreId() {
		return storeId;
	}

	public void setStoreId(int storeId) {
		this.storeId = storeId;
	}

	public int getYearId() {
		return yearId;
	}

	public void setYearId(int yearId) {
		this.yearId = yearId;
	}

	public int getQuarterId() {
		return quarterId;
	}

	public void setQuarterId(int quarterId) {
		this.quarterId = quarterId;
	}

	public int getBrandId() {
		return brandId;
	}

	public void setBrandId(int brandId) {
		this.brandId = brandId;
	}

	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}

	public int getParentId() {
		return parentId;
	}
	public void setParentId(int parentId) {
		this.parentId = parentId;
	}
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public int getInventory() {
		return inventory;
	}
	public void setInventory(int inventory) {
		this.inventory = inventory;
	}
	public String getState() {
		return state;
	}
	public void setState(String state) {
		this.state = state;
	}
	public String getParam() {
		return param;
	}
	public void setParam(String param) {
		this.param = param;
	}

	public int getBeforeAmount() {
		return beforeAmount;
	}

	public void setBeforeAmount(int beforeAmount) {
		this.beforeAmount = beforeAmount;
	}

	public double getBeforeAmountMoney() {
		return beforeAmountMoney;
	}

	public void setBeforeAmountMoney(double beforeAmountMoney) {
		this.beforeAmountMoney = beforeAmountMoney;
	}

	public int getPeriodPurchaseNums() {
		return periodPurchaseNums;
	}

	public void setPeriodPurchaseNums(int periodPurchaseNums) {
		this.periodPurchaseNums = periodPurchaseNums;
	}

	public double getPeriodPurchaseMoneys() {
		return periodPurchaseMoneys;
	}

	public void setPeriodPurchaseMoneys(double periodPurchaseMoneys) {
		this.periodPurchaseMoneys = periodPurchaseMoneys;
	}

	public int getPeriodSaleReturnNums() {
		return periodSaleReturnNums;
	}

	public void setPeriodSaleReturnNums(int periodSaleReturnNums) {
		this.periodSaleReturnNums = periodSaleReturnNums;
	}

	public double getPeriodSaleReturnMoneys() {
		return periodSaleReturnMoneys;
	}

	public void setPeriodSaleReturnMoneys(double periodSaleReturnMoneys) {
		this.periodSaleReturnMoneys = periodSaleReturnMoneys;
	}

	public int getPeriodOverflowNums() {
		return periodOverflowNums;
	}

	public void setPeriodOverflowNums(int periodOverflowNums) {
		this.periodOverflowNums = periodOverflowNums;
	}

	public int getPeriodReceiveNums() {
		return periodReceiveNums;
	}

	public void setPeriodReceiveNums(int periodReceiveNums) {
		this.periodReceiveNums = periodReceiveNums;
	}

	public int getPeriodSaleNums() {
		return periodSaleNums;
	}

	public void setPeriodSaleNums(int periodSaleNums) {
		this.periodSaleNums = periodSaleNums;
	}

	public double getPeriodSaleMoneys() {
		return periodSaleMoneys;
	}

	public void setPeriodSaleMoneys(double periodSaleMoneys) {
		this.periodSaleMoneys = periodSaleMoneys;
	}

	public int getPeriodPurchaseReturnNums() {
		return periodPurchaseReturnNums;
	}

	public void setPeriodPurchaseReturnNums(int periodPurchaseReturnNums) {
		this.periodPurchaseReturnNums = periodPurchaseReturnNums;
	}

	public double getPeriodPurchaseReturnMoneys() {
		return periodPurchaseReturnMoneys;
	}

	public void setPeriodPurchaseReturnMoneys(double periodPurchaseReturnMoneys) {
		this.periodPurchaseReturnMoneys = periodPurchaseReturnMoneys;
	}

	public int getPeriodLossNums() {
		return periodLossNums;
	}

	public void setPeriodLossNums(int periodLossNums) {
		this.periodLossNums = periodLossNums;
	}

	public int getPeriodGiftNums() {
		return periodGiftNums;
	}

	public void setPeriodGiftNums(int periodGiftNums) {
		this.periodGiftNums = periodGiftNums;
	}

	public int getTotalQuantity() {
		return totalQuantity;
	}

	public void setTotalQuantity(int totalQuantity) {
		this.totalQuantity = totalQuantity;
	}

	public double getTotalAmount() {
		return totalAmount;
	}

	public void setTotalAmount(double totalAmount) {
		this.totalAmount = totalAmount;
	}

	public double getPeriodOverflowMoneys() {
		return periodOverflowMoneys;
	}

	public void setPeriodOverflowMoneys(double periodOverflowMoneys) {
		this.periodOverflowMoneys = periodOverflowMoneys;
	}

	public double getPeriodReceiveMoneys() {
		return periodReceiveMoneys;
	}

	public void setPeriodReceiveMoneys(double periodReceiveMoneys) {
		this.periodReceiveMoneys = periodReceiveMoneys;
	}

	public double getPeriodLossMoneys() {
		return periodLossMoneys;
	}

	public void setPeriodLossMoneys(double periodLossMoneys) {
		this.periodLossMoneys = periodLossMoneys;
	}

	public double getPeriodGiftMoneys() {
		return periodGiftMoneys;
	}

	public void setPeriodGiftMoneys(double periodGiftMoneys) {
		this.periodGiftMoneys = periodGiftMoneys;
	}

	public int getPeriodCallInNums() {
		return periodCallInNums;
	}

	public void setPeriodCallInNums(int periodCallInNums) {
		this.periodCallInNums = periodCallInNums;
	}

	public double getPeriodCallInMoneys() {
		return periodCallInMoneys;
	}

	public void setPeriodCallInMoneys(double periodCallInMoneys) {
		this.periodCallInMoneys = periodCallInMoneys;
	}

	public int getPeriodOutNums() {
		return periodOutNums;
	}

	public void setPeriodOutNums(int periodOutNums) {
		this.periodOutNums = periodOutNums;
	}

	public double getPeriodOutMoneys() {
		return periodOutMoneys;
	}

	public void setPeriodOutMoneys(double periodOutMoneys) {
		this.periodOutMoneys = periodOutMoneys;
	}

	public int getPeriodEnterNums() {
		return periodEnterNums;
	}

	public void setPeriodEnterNums(int periodEnterNums) {
		this.periodEnterNums = periodEnterNums;
	}

	public double getPeriodEnterMoneys() {
		return periodEnterMoneys;
	}

	public void setPeriodEnterMoneys(double periodEnterMoneys) {
		this.periodEnterMoneys = periodEnterMoneys;
	}

	public int getPeriodOutBoundNums() {
		return periodOutBoundNums;
	}

	public void setPeriodOutBoundNums(int periodOutBoundNums) {
		this.periodOutBoundNums = periodOutBoundNums;
	}

	public double getPeriodOutBoundMoneys() {
		return periodOutBoundMoneys;
	}

	public void setPeriodOutBoundMoneys(double periodOutBoundMoneys) {
		this.periodOutBoundMoneys = periodOutBoundMoneys;
	}

	public ProductBarcode getPb() {
		return pb;
	}

	public void setPb(ProductBarcode pb) {
		this.pb = pb;
	}

	@Override
	public String toString() {
		return "HqInventoryChangeDetailsVO [id=" + id + ", storeName=" + storeName + ", name=" + name + ", barcode="
				+ barcode + ", inventory=" + inventory + ", state=" + state + ", param=" + param + ", parentId="
				+ parentId + ", storeId=" + storeId + ", yearId=" + yearId + ", quarterId=" + quarterId + ", brandId="
				+ brandId + ", categoryId=" + categoryId + ", categoryLevelId=" + categoryLevelId + ", pbId=" + pbId
				+ ", beforeAmount=" + beforeAmount + ", beforeAmountMoney=" + beforeAmountMoney
				+ ", periodPurchaseNums=" + periodPurchaseNums + ", periodPurchaseMoneys=" + periodPurchaseMoneys
				+ ", periodSaleReturnNums=" + periodSaleReturnNums + ", periodSaleReturnMoneys="
				+ periodSaleReturnMoneys + ", periodOverflowNums=" + periodOverflowNums + ", periodOverflowMoneys="
				+ periodOverflowMoneys + ", periodReceiveNums=" + periodReceiveNums + ", periodReceiveMoneys="
				+ periodReceiveMoneys + ", periodCallInNums=" + periodCallInNums + ", periodCallInMoneys="
				+ periodCallInMoneys + ", periodEnterNums=" + periodEnterNums + ", periodEnterMoneys="
				+ periodEnterMoneys + ", periodSaleNums=" + periodSaleNums + ", periodSaleMoneys=" + periodSaleMoneys
				+ ", periodPurchaseReturnNums=" + periodPurchaseReturnNums + ", periodPurchaseReturnMoneys="
				+ periodPurchaseReturnMoneys + ", periodLossNums=" + periodLossNums + ", periodLossMoneys="
				+ periodLossMoneys + ", periodGiftNums=" + periodGiftNums + ", periodGiftMoneys=" + periodGiftMoneys
				+ ", periodOutNums=" + periodOutNums + ", periodOutMoneys=" + periodOutMoneys + ", periodOutBoundNums="
				+ periodOutBoundNums + ", periodOutBoundMoneys=" + periodOutBoundMoneys + ", totalQuantity="
				+ totalQuantity + ", totalAmount=" + totalAmount + "]";
	}

	
	
	
}
